<?php
/**
 * Created by litong on Date: 2019/4/10 0010 下午 11:52
 * 高德天气查询客户端
 */
class WeatherClient {

  public function  getServerUrl(){
    return "https://restapi.amap.com/v3/weather/weatherInfo";
  }

  /**
   * 解析文件,获取key
   */
  public function  getKey(){
    $filePath="D:\dev_workspace\secret\config.ini";
    $data = parse_ini_file($filePath,true);
    return $data['gaode']['key01'];
  }

  /**
   * 查询天气
   */
  public function getWeather($cityCode){
    $data=$this->getKey();
    var_dump($data);
  }

}